<?php
namespace app\admin\model\system;
use think\facade\Db;
use think\admin\common;
class ShadowProduct{
	
	public function insertProduct($_data){
		return Db::name("shadow_product_setting")->insertGetId($_data);
	}
	
	public function updateData($_up,$_where)
	{
		return Db::name("shadow_product_setting")->where($_where)->update($_up);
	}
	
	public function findProductSetting($_where,$_field){
		return Db::name("shadow_product_setting")->where($_where)->field($_field)->find();
	}
	
	public function selectProductSetting($_where,$_field,$_limit,$_order){
		$_data=Db::name("shadow_product_setting")->where($_where)->field($_field)->limit(current($_limit),next($_limit))->order($_order)->select();
		return empty($_data)?[]:$_data->toArray();
	}
}
?>